package com.sc.VenusQueryBeta.contract.login;

import com.hengjun.kingstar.sdk.base.BasePresenter;
import com.hengjun.kingstar.sdk.base.IBaseActivity;
import com.hengjun.kingstar.sdk.base.IBaseFragment;
import com.hengjun.kingstar.sdk.base.IBaseModel;
import com.sc.VenusQueryBeta.model.bean.login.EquipmentLoginBean;
import com.sc.VenusQueryBeta.model.bean.login.FirstLoginSubmintBean;

import io.reactivex.Observable;

/**
 * Created by SC-02 on 2018/9/19.
 *  登錄Contract(契约)接口
 */

public interface FirstLoginContract {
    abstract class LoginPresenter extends BasePresenter<ILoginModel,ILoginView> {
        //第一次登陆设备，获取验证码
        public abstract void getFirstBUserLoginCode(String clientUID, String deviceUID, String deviceType, String registerSmsnum);
        //第一次登录的页面确定后继续掉通过伺服器确认注册
        public abstract void firstSumbit(String id, String smsCode, String password, String clientUID, String deviceUID, String deviceType);
    }
    interface  ILoginModel extends IBaseModel{
        //第一次登陆设备，获取验证码
        Observable<EquipmentLoginBean> getFirstBUserLoginCode(String clientUID, String deviceUID, String deviceType, String registerSmsnum);
        //第一次登录的页面确定后继续掉通过伺服器确认注册
        Observable<FirstLoginSubmintBean> firstSumbit(String id, String smsCode, String password, String clientUID, String deviceUID, String deviceType);
    }
    interface  ILoginView extends IBaseActivity{
        void showNetworkError();

        //第一次登陸 綁定設備時 發送驗證碼
        void showFirstBUserLoginCodeSuccess(EquipmentLoginBean equipmentLoginBean);

        //第一次登陸 綁定設備時 確認驗證碼
        void showFirstSumbitDataSuccess(FirstLoginSubmintBean firstLoginSubmintBean);
    }
}
